3.52 \(\int \cot ^6(c+d x) (a+a \sec (c+d x))^3 \, dx\)

Optimal. Leaf size=107 \[ -\frac {4 a^3 \cot ^5(c+d x)}{5 d}+\frac {a^3 \cot ^3(c+d x)}{3 d}-\frac {a^3 \cot (c+d x)}{d}-\frac {4 a^3 \csc ^5(c+d x)}{5 d}+\frac {7 a^3 \csc ^3(c+d x)}{3 d}-\frac {3 a^3 \csc (c+d x)}{d}-a^3 x \]

[Out]

-a^3*x-a^3*cot(d*x+c)/d+1/3*a^3*cot(d*x+c)^3/d-4/5*a^3*cot(d*x+c)^5/d-3*a^3*csc(d*x+c)/d+7/3*a^3*csc(d*x+c)^3/
d-4/5*a^3*csc(d*x+c)^5/d

________________________________________________________________________________________

Rubi [A]  time = 0.16, antiderivative size = 107, normalized size of antiderivative = 1.00, number of steps used = 14, number of rules used = 8, integrand size = 21, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.381, Rules used = {3886, 3473, 8, 2606, 194, 2607, 30, 14} \[ -\frac {4 a^3 \cot ^5(c+d x)}{5 d}+\frac {a^3 \cot ^3(c+d x)}{3 d}-\frac {a^3 \cot (c+d x)}{d}-\frac {4 a^3 \csc ^5(c+d x)}{5 d}+\frac {7 a^3 \csc ^3(c+d x)}{3 d}-\frac {3 a^3 \csc (c+d x)}{d}-a^3 x \]

Antiderivative was successfully verified.

[In]

Int[Cot[c + d*x]^6*(a + a*Sec[c + d*x])^3,x]

[Out]

-(a^3*x) - (a^3*Cot[c + d*x])/d + (a^3*Cot[c + d*x]^3)/(3*d) - (4*a^3*Cot[c + d*x]^5)/(5*d) - (3*a^3*Csc[c + d
*x])/d + (7*a^3*Csc[c + d*x]^3)/(3*d) - (4*a^3*Csc[c + d*x]^5)/(5*d)

Rule 8

Int[a_, x_Symbol] :> Simp[a*x, x] /; FreeQ[a, x]

Rule 14

Int[(u_)*((c_.)*(x_))^(m_.), x_Symbol] :> Int[ExpandIntegrand[(c*x)^m*u, x], x] /; FreeQ[{c, m}, x] && SumQ[u]
 &&  !LinearQ[u, x] &&  !MatchQ[u, (a_) + (b_.)*(v_) /; FreeQ[{a, b}, x] && InverseFunctionQ[v]]

Rule 30

Int[(x_)^(m_.), x_Symbol] :> Simp[x^(m + 1)/(m + 1), x] /; FreeQ[m, x] && NeQ[m, -1]

Rule 194

Int[((a_) + (b_.)*(x_)^(n_))^(p_), x_Symbol] :> Int[ExpandIntegrand[(a + b*x^n)^p, x], x] /; FreeQ[{a, b}, x]
&& IGtQ[n, 0] && IGtQ[p, 0]

Rule 2606

Int[((a_.)*sec[(e_.) + (f_.)*(x_)])^(m_.)*((b_.)*tan[(e_.) + (f_.)*(x_)])^(n_.), x_Symbol] :> Dist[a/f, Subst[
Int[(a*x)^(m - 1)*(-1 + x^2)^((n - 1)/2), x], x, Sec[e + f*x]], x] /; FreeQ[{a, e, f, m}, x] && IntegerQ[(n -
1)/2] &&  !(IntegerQ[m/2] && LtQ[0, m, n + 1])

Rule 2607

Int[sec[(e_.) + (f_.)*(x_)]^(m_)*((b_.)*tan[(e_.) + (f_.)*(x_)])^(n_.), x_Symbol] :> Dist[1/f, Subst[Int[(b*x)
^n*(1 + x^2)^(m/2 - 1), x], x, Tan[e + f*x]], x] /; FreeQ[{b, e, f, n}, x] && IntegerQ[m/2] &&  !(IntegerQ[(n
- 1)/2] && LtQ[0, n, m - 1])

Rule 3473

Int[((b_.)*tan[(c_.) + (d_.)*(x_)])^(n_), x_Symbol] :> Simp[(b*(b*Tan[c + d*x])^(n - 1))/(d*(n - 1)), x] - Dis
t[b^2, Int[(b*Tan[c + d*x])^(n - 2), x], x] /; FreeQ[{b, c, d}, x] && GtQ[n, 1]

Rule 3886

Int[(cot[(c_.) + (d_.)*(x_)]*(e_.))^(m_)*(csc[(c_.) + (d_.)*(x_)]*(b_.) + (a_))^(n_), x_Symbol] :> Int[ExpandI
ntegrand[(e*Cot[c + d*x])^m, (a + b*Csc[c + d*x])^n, x], x] /; FreeQ[{a, b, c, d, e, m}, x] && IGtQ[n, 0]

Rubi steps

\begin {align*} \int \cot ^6(c+d x) (a+a \sec (c+d x))^3 \, dx &=\int \left (a^3 \cot ^6(c+d x)+3 a^3 \cot ^5(c+d x) \csc (c+d x)+3 a^3 \cot ^4(c+d x) \csc ^2(c+d x)+a^3 \cot ^3(c+d x) \csc ^3(c+d x)\right ) \, dx\\ &=a^3 \int \cot ^6(c+d x) \, dx+a^3 \int \cot ^3(c+d x) \csc ^3(c+d x) \, dx+\left (3 a^3\right ) \int \cot ^5(c+d x) \csc (c+d x) \, dx+\left (3 a^3\right ) \int \cot ^4(c+d x) \csc ^2(c+d x) \, dx\\ &=-\frac {a^3 \cot ^5(c+d x)}{5 d}-a^3 \int \cot ^4(c+d x) \, dx-\frac {a^3 \operatorname {Subst}\left (\int x^2 \left (-1+x^2\right ) \, dx,x,\csc (c+d x)\right )}{d}+\frac {\left (3 a^3\right ) \operatorname {Subst}\left (\int x^4 \, dx,x,-\cot (c+d x)\right )}{d}-\frac {\left (3 a^3\right ) \operatorname {Subst}\left (\int \left (-1+x^2\right )^2 \, dx,x,\csc (c+d x)\right )}{d}\\ &=\frac {a^3 \cot ^3(c+d x)}{3 d}-\frac {4 a^3 \cot ^5(c+d x)}{5 d}+a^3 \int \cot ^2(c+d x) \, dx-\frac {a^3 \operatorname {Subst}\left (\int \left (-x^2+x^4\right ) \, dx,x,\csc (c+d x)\right )}{d}-\frac {\left (3 a^3\right ) \operatorname {Subst}\left (\int \left (1-2 x^2+x^4\right ) \, dx,x,\csc (c+d x)\right )}{d}\\ &=-\frac {a^3 \cot (c+d x)}{d}+\frac {a^3 \cot ^3(c+d x)}{3 d}-\frac {4 a^3 \cot ^5(c+d x)}{5 d}-\frac {3 a^3 \csc (c+d x)}{d}+\frac {7 a^3 \csc ^3(c+d x)}{3 d}-\frac {4 a^3 \csc ^5(c+d x)}{5 d}-a^3 \int 1 \, dx\\ &=-a^3 x-\frac {a^3 \cot (c+d x)}{d}+\frac {a^3 \cot ^3(c+d x)}{3 d}-\frac {4 a^3 \cot ^5(c+d x)}{5 d}-\frac {3 a^3 \csc (c+d x)}{d}+\frac {7 a^3 \csc ^3(c+d x)}{3 d}-\frac {4 a^3 \csc ^5(c+d x)}{5 d}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.67, size = 112, normalized size = 1.05 \[ -\frac {a^3 (\cos (c+d x)+1)^3 \sec ^6\left (\frac {1}{2} (c+d x)\right ) \left (\cot \left (\frac {c}{2}\right ) (13 \cos (c+d x)-10) \csc ^4\left (\frac {1}{2} (c+d x)\right )+\csc \left (\frac {c}{2}\right ) \sin \left (\frac {d x}{2}\right ) (51 \cos (c+d x)-16 \cos (2 (c+d x))-38) \csc ^5\left (\frac {1}{2} (c+d x)\right )+60 d x\right )}{480 d} \]

Antiderivative was successfully verified.

[In]

Integrate[Cot[c + d*x]^6*(a + a*Sec[c + d*x])^3,x]

[Out]

-1/480*(a^3*(1 + Cos[c + d*x])^3*Sec[(c + d*x)/2]^6*(60*d*x + (-10 + 13*Cos[c + d*x])*Cot[c/2]*Csc[(c + d*x)/2
]^4 + (-38 + 51*Cos[c + d*x] - 16*Cos[2*(c + d*x)])*Csc[c/2]*Csc[(c + d*x)/2]^5*Sin[(d*x)/2]))/d

________________________________________________________________________________________

fricas [A]  time = 0.75, size = 118, normalized size = 1.10 \[ -\frac {32 \, a^{3} \cos \left (d x + c\right )^{3} - 19 \, a^{3} \cos \left (d x + c\right )^{2} - 29 \, a^{3} \cos \left (d x + c\right ) + 22 \, a^{3} + 15 \, {\left (a^{3} d x \cos \left (d x + c\right )^{2} - 2 \, a^{3} d x \cos \left (d x + c\right ) + a^{3} d x\right )} \sin \left (d x + c\right )}{15 \, {\left (d \cos \left (d x + c\right )^{2} - 2 \, d \cos \left (d x + c\right ) + d\right )} \sin \left (d x + c\right )} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cot(d*x+c)^6*(a+a*sec(d*x+c))^3,x, algorithm="fricas")

[Out]

-1/15*(32*a^3*cos(d*x + c)^3 - 19*a^3*cos(d*x + c)^2 - 29*a^3*cos(d*x + c) + 22*a^3 + 15*(a^3*d*x*cos(d*x + c)
^2 - 2*a^3*d*x*cos(d*x + c) + a^3*d*x)*sin(d*x + c))/((d*cos(d*x + c)^2 - 2*d*cos(d*x + c) + d)*sin(d*x + c))

________________________________________________________________________________________

giac [A]  time = 0.36, size = 66, normalized size = 0.62 \[ -\frac {60 \, {\left (d x + c\right )} a^{3} + \frac {105 \, a^{3} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{4} - 20 \, a^{3} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} + 3 \, a^{3}}{\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{5}}}{60 \, d} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cot(d*x+c)^6*(a+a*sec(d*x+c))^3,x, algorithm="giac")

[Out]

-1/60*(60*(d*x + c)*a^3 + (105*a^3*tan(1/2*d*x + 1/2*c)^4 - 20*a^3*tan(1/2*d*x + 1/2*c)^2 + 3*a^3)/tan(1/2*d*x
 + 1/2*c)^5)/d

________________________________________________________________________________________

maple [B]  time = 1.07, size = 232, normalized size = 2.17 \[ \frac {a^{3} \left (-\frac {\left (\cot ^{5}\left (d x +c \right )\right )}{5}+\frac {\left (\cot ^{3}\left (d x +c \right )\right )}{3}-\cot \left (d x +c \right )-d x -c \right )+3 a^{3} \left (-\frac {\cos ^{6}\left (d x +c \right )}{5 \sin \left (d x +c \right )^{5}}+\frac {\cos ^{6}\left (d x +c \right )}{15 \sin \left (d x +c \right )^{3}}-\frac {\cos ^{6}\left (d x +c \right )}{5 \sin \left (d x +c \right )}-\frac {\left (\frac {8}{3}+\cos ^{4}\left (d x +c \right )+\frac {4 \left (\cos ^{2}\left (d x +c \right )\right )}{3}\right ) \sin \left (d x +c \right )}{5}\right )-\frac {3 a^{3} \left (\cos ^{5}\left (d x +c \right )\right )}{5 \sin \left (d x +c \right )^{5}}+a^{3} \left (-\frac {\cos ^{4}\left (d x +c \right )}{5 \sin \left (d x +c \right )^{5}}-\frac {\cos ^{4}\left (d x +c \right )}{15 \sin \left (d x +c \right )^{3}}+\frac {\cos ^{4}\left (d x +c \right )}{15 \sin \left (d x +c \right )}+\frac {\left (2+\cos ^{2}\left (d x +c \right )\right ) \sin \left (d x +c \right )}{15}\right )}{d} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(cot(d*x+c)^6*(a+a*sec(d*x+c))^3,x)

[Out]

1/d*(a^3*(-1/5*cot(d*x+c)^5+1/3*cot(d*x+c)^3-cot(d*x+c)-d*x-c)+3*a^3*(-1/5/sin(d*x+c)^5*cos(d*x+c)^6+1/15/sin(
d*x+c)^3*cos(d*x+c)^6-1/5/sin(d*x+c)*cos(d*x+c)^6-1/5*(8/3+cos(d*x+c)^4+4/3*cos(d*x+c)^2)*sin(d*x+c))-3/5*a^3/
sin(d*x+c)^5*cos(d*x+c)^5+a^3*(-1/5/sin(d*x+c)^5*cos(d*x+c)^4-1/15/sin(d*x+c)^3*cos(d*x+c)^4+1/15/sin(d*x+c)*c
os(d*x+c)^4+1/15*(2+cos(d*x+c)^2)*sin(d*x+c)))

________________________________________________________________________________________

maxima [A]  time = 0.44, size = 122, normalized size = 1.14 \[ -\frac {{\left (15 \, d x + 15 \, c + \frac {15 \, \tan \left (d x + c\right )^{4} - 5 \, \tan \left (d x + c\right )^{2} + 3}{\tan \left (d x + c\right )^{5}}\right )} a^{3} + \frac {3 \, {\left (15 \, \sin \left (d x + c\right )^{4} - 10 \, \sin \left (d x + c\right )^{2} + 3\right )} a^{3}}{\sin \left (d x + c\right )^{5}} - \frac {{\left (5 \, \sin \left (d x + c\right )^{2} - 3\right )} a^{3}}{\sin \left (d x + c\right )^{5}} + \frac {9 \, a^{3}}{\tan \left (d x + c\right )^{5}}}{15 \, d} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cot(d*x+c)^6*(a+a*sec(d*x+c))^3,x, algorithm="maxima")

[Out]

-1/15*((15*d*x + 15*c + (15*tan(d*x + c)^4 - 5*tan(d*x + c)^2 + 3)/tan(d*x + c)^5)*a^3 + 3*(15*sin(d*x + c)^4
- 10*sin(d*x + c)^2 + 3)*a^3/sin(d*x + c)^5 - (5*sin(d*x + c)^2 - 3)*a^3/sin(d*x + c)^5 + 9*a^3/tan(d*x + c)^5
)/d

________________________________________________________________________________________

mupad [B]  time = 1.45, size = 62, normalized size = 0.58 \[ \frac {a^3\,{\mathrm {cot}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^3}{3\,d}-a^3\,x-\frac {a^3\,{\mathrm {cot}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^5}{20\,d}-\frac {7\,a^3\,\mathrm {cot}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}{4\,d} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(cot(c + d*x)^6*(a + a/cos(c + d*x))^3,x)

[Out]

(a^3*cot(c/2 + (d*x)/2)^3)/(3*d) - a^3*x - (a^3*cot(c/2 + (d*x)/2)^5)/(20*d) - (7*a^3*cot(c/2 + (d*x)/2))/(4*d
)

________________________________________________________________________________________

sympy [F(-1)]  time = 0.00, size = 0, normalized size = 0.00 \[ \text {Timed out} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cot(d*x+c)**6*(a+a*sec(d*x+c))**3,x)

[Out]

Timed out

________________________________________________________________________________________